﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DataLayer
{
    public class DeleteNodeCommand : ActionCommand
    {
        public DeleteNodeCommand(Node _data)
        {
            data = _data;
            parent = _data.ParentNode;
        }

        public override void Excute()
        {
            parent.DelecteNode(data);
        }

        public override void UndoExcute()
        {
            parent.AddNode(data);
        }
    }
}
